﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/MainFrame.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<GPMS.Model.GPSelectionVM>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    学生列表
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

<h2>用户列表</h2>
 <p>
        <%: Html.ActionLink("返回", "TeacherGPList", "GraduationProject", new { id = ViewData["gpid"] }, new { @class = "button" })%>
    </p>
<table id="userselectonlist">
    <tr>
        <th>操作</th>
        <th>
            课题名称
        </th>
        <th>
            学生
        </th>
    </tr>

<% foreach (var item in Model) { %>
    <tr>
    <%if (item.Selection.IsConfirm)
      {%>
         <td>
            <%: Html.ActionLink("计划管理", "List","Plan", new { id = item.Selection.SelectionID }, new { @class = "button" })%>
        </td>
      <%}
      else
      {%>
           <td>
            <%: Html.ActionLink("确定", "ConfirmSelection", new { id = item.Selection.SelectionID }, new { @class = "dialog" })%> |
            <%: Html.ActionLink("删除", "Delete", new { id=item.Selection.SelectionID },new { @class = "dialog"}) %>
        </td>
       <%}%>
       
        <td>
            <%:item.Project.GPName %>
        </td>

        <td>
            <%: item.Selector %>
        </td>
    </tr>  
<% } %>

</table>

</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="Header" runat="server">
     <link href="<%=Url.Content("~/Content/css/ui.jqgrid.css") %>" rel="Stylesheet" type="text/css" />
    <link href="<%=Url.Content("~/Content/css/admin.css") %>" rel="Stylesheet" type="text/css" />
    <script type="text/javascript" src="<%=Url.Content("~/Scripts/i18n/grid.locale-cn.js") %>"></script>
    <script type="text/javascript" src="<%=Url.Content("~/Scripts/jquery.jqGrid.min.js") %>"></script>
    <style type="text/css">
        body
        {
            background: white;
        }
    </style>
    <script type="text/javascript">
        $(function () {
            tableToGrid($("#userselectonlist"), { width: 640, height: 320 });
            DialogLink($("a.dialog"), $("#dialogPanel"), { close: function () {
                $.unblockUI();
                //window.location.reload();
            }
            });
        });
        var reflashTag = {};
    </script>

</asp:Content>

